<?php
/* SVN FILE: $Id: default.ctp 7945 2008-12-19 02:16:01Z gwoo $ */
/**
 *
 * PHP versions 4 and 5
 *
 * CakePHP(tm) :  Rapid Development Framework (http://www.cakephp.org)
 * Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org)
 *
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 *
 * @filesource
 * @copyright     Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org)
 * @link          http://www.cakefoundation.org/projects/info/cakephp CakePHP(tm) Project
 * @package       cake
 * @subpackage    cake.cake.libs.view.templates.layouts
 * @since         CakePHP(tm) v 0.10.0.1076
 * @version       $Revision: 7945 $
 * @modifiedby    $LastChangedBy: gwoo $
 * @lastmodified  $Date: 2008-12-18 21:16:01 -0500 (Thu, 18 Dec 2008) $
 * @license       http://www.opensource.org/licenses/mit-license.php The MIT License
 */
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<?php echo $html->charset(); ?>
	<title>
		<?php __('Family Newsletter'); ?>
		<?php echo $title_for_layout; ?>
	</title>
	
	<script type="text/javascript" src="/js/jquery/jquery.js"></script>
	<script type="text/javascript" src="/js/jquery/ui/ui.core.js"></script>
	
	<link rel="stylesheet" type="text/css" href="/css/ui.autocomplete.css" />
	<script type="text/javascript" src="/js/jquery/ui/ui.autocomplete.js"></script>
	
	<link rel="stylesheet" type="text/css" href="/css/facebox.css" />
	<script type="text/javascript" src="/js/facebox.js"></script>
	
	<?php
		echo $html->meta('icon');

		echo $html->css('cake.generic');

		echo $scripts_for_layout;
	?>
	
	<script type="text/javascript">
		$(document).ready(function(){
			$("#personSearch").autocomplete({
				url: "/people/autoComplete"
			});
			
			$("#personSearch").focus(function(){
				if ($("#personSearch").val() == "Search...") {
					$("#personSearch").val("");
				} else {
					$("#personSearch").select();
				}
			});
			
			$("#personSearch").blur(function(){
				if ($("#personSearch").val() == "") {
					$("#personSearch").val("Search...");
				}
			});
			
			$("#personSearch").keypress(function(e){
				if (e.keyCode == 13) {
					window.location = "/people/view/" + escape($("#personSearch").val());
				}
			});
			
			$('a[rel*=facebox]').facebox();
		});
	</script>
</head>
<body>
	<div id="container">
		<div id="header">
			<h1 style="position:absolute;left:10px;"><?php echo $html->link(__('Family Newsletter', true), '/'); ?></h1>
			<input id="personSearch" type="text" value="Search..." style="position:absolute;right:10px;" />
			<div style="height:25px;"></div>
		</div>
		<div id="content">

			<?php $session->flash(); ?>

			<?php echo $content_for_layout; ?>

		</div>
		<div id="footer">
			<?php echo $html->link(
					$html->image('cake.power.gif', array('alt'=> __("CakePHP: the rapid development php framework", true), 'border'=>"0")),
					'http://www.cakephp.org/',
					array('target'=>'_blank'), null, false
				);
			?>
		</div>
	</div>
	<?php echo $cakeDebug; ?>
</body>
</html>